/*
 * Copyright (c) 2006-2021, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2022-08-18     SY       the first version
 */
#ifndef APPLICATIONS_SY_FS_H_
#define APPLICATIONS_SY_FS_H_

typedef struct _disk
{
    char name[16];
    unsigned int *start_addr;
    unsigned int disk_size;
    unsigned int *base_addr;

}disk_t;

typedef disk_t *Disk;

typedef struct _file
{
    char name[16];
    unsigned char type;
    unsigned int size;
    void *data;
    struct _file *next;

}file_t;

typedef file_t *File;

typedef struct _fat
{
    disk_t disk;
    file_t file;
    unsigned int file_size;
    unsigned int offset;

}fat_t;

typedef fat_t *Fat;

Fat fs_init();

#endif /* APPLICATIONS_SY_FS_H_ */
